package me.xiaosiqi.service.store;


import com.github.pagehelper.PageInfo;
import me.xiaosiqi.domain.store.Question;
import org.apache.commons.fileupload.FileItem;

import java.io.IOException;
import java.util.List;

public interface QuestionService {

    /**
     * 添加
     * @param question
     */
    void save(List<FileItem> question,String path);

    /**
     * 删除
     * @param question
     */
    void delete(Question question,String path);

    /**
     * 修改
     * @param question
     */
    void update(List<FileItem> question,String path);



    /**
     * 根据id查找
     * @param id
     * @return
     */
    Question findById(String id);

    /**
     * 查询所有
     * @return
     */
    List<Question> findAll();

    /**
     * 分页查询
     * @return
     */
    PageInfo findPage(int page, int size);

    /**
     * 报表数据
     */
    void getReport(String path) throws IOException;
}
